package com.jyw.system.domain.dto;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.jyw.common.core.domain.entity.SysRole;
import com.jyw.common.utils.bean.BeanUtils;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.Date;

@Data
@ApiModel("角色分页查询")
@NoArgsConstructor
public class SysRolePageDto extends SysRole {

    @ApiModelProperty("创建开始时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm")
    private Date beginTime;

    @ApiModelProperty("创建结束时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm")
    private Date endTime;

    public SysRolePageDto(SysRole role) {
        BeanUtils.copyProperties(role,this);
    }
}
